#include<bits/stdc++.h>
using namespace std;
int a[2501 * 25];// WA 数组开小了
int cnt = 0;

void judprog(int judgement)
{
	int wtimes = 0;
	int ltimes = 0;
	for (int i = 0; i < cnt; i++) {

		if (a[i] == 1) {
			wtimes ++;
		}
		if (a[i] == 0) {
			ltimes ++;
		}
		if ( (wtimes >= judgement || ltimes >= judgement) && abs(wtimes - ltimes) >= 2 ) {
			cout << wtimes << ":" << ltimes << endl;
			ltimes = 0;
			wtimes = 0;

		}
	}
//	if (ltimes * wtimes != 0) {//WA 00也输出
	cout << wtimes << ":" << ltimes << endl;
//	}
}
int main()
{
	char x;
	while (true) {
		cin >> x;
		if (x == 'E') {
			break;
		}
		if (x ==  'W') {
			a[cnt++] = 1;
		}
		if (x == 'L') {
			a[cnt++] = 0;
		}
	}
	judprog(11);
	cout << endl;
	judprog(21);

	return 0;
}
